#ifndef LIMITERWIDGET_H
#define LIMITERWIDGET_H


#include "dm/dmstruct.h"
#include "dynamicxucs.h"


class LimiterWidget : public QWidget
{
    Q_OBJECT
public:

    explicit LimiterWidget(const double &maxThreshold, QWidget *parent = nullptr);
    Limiter getData() const;
signals:
    void stateChanged(Limiter);
public slots:
    void set(const Limiter &data);
private:
    void valueChanged();
private:
    ALabel *thresholdLabel;
    ALabel *attackLabel;
    ALabel *decayLabel;
    ADoubleSpinBox *thresholdSpinBox;
    ASpinBox *attackSpinBox;
    ASpinBox *decaySpinBox;
    DynamicXUCS *ucs;
};

#endif // LIMITERWIDGET_H
